<div class="container-fluid">
    <div class="row">
        <div class="col-sm">
            <h3 class="text-muted">订单信息</h3>
                <table class="table custom-data-table data-table table-bordered complex-headers">
                    <thead>
                    <tr>
                        <th>订单号</th>
                        <th>实际付款</th>
                        <th>买家</th>
                        <th>订单状态</th>
                        <th>支付方式</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr>
                        <td style="width: 280px">订单号：{{$order->order_no}}</td>
                        <td>付款金额：{{$order->order_price}}</td>
                        <td>买家：{{$order->userInfo['nickname']}}</td>
                        <td>
                            @if ($order->status == 0)
                            <span class="badge badge-warning">待支付</span>
                            @elseif ($order->status == 1)
                            <span class="badge badge-success">支付成功</span>
                            @elseif ($order->status == 2)
                            <span class="badge badge-warning">支付失败</span>
                            @elseif ($order->status == 4)
                                <span class="badge badge-warning">订单已发货，待收货</span>
                            @else
                                <span class="badge badge-warning">其他</span>

                            @endif
                        </td>

                        <td>
                            @if ($order->pay_status == 0)
                                <span class="badge badge-warning">钱包支付</span>
                            @elseif ($order->status == 1)
                                <span class="badge badge-success">微信支付</span>
                            @elseif ($order->pay_status == 1 && $order->status==0)
                                <span class="badge badge-success">暂未支付</span>
                            @endif
                        </td>

                    </tr>
                    </tbody>
                </table>
        </div>
    </div>
    <div class="row" style="margin-top: 12px">

        @if ($order->order_type==1)
        <div class="col-sm">
            <h3 class="text-muted">商品信息</h3>
                <table class="table custom-data-table data-table table-bordered complex-headers">
                    <thead>
                    <tr>
                        <th>商品名称</th>
                        <th>商品价格</th>
                        <th>购买数量</th>
{{--                        <th>购买权限</th>--}}
                    </tr>
                    </thead>
                    <tbody>
                    <tr>
                        <td style="width: 280px">名称：{{$order->order_goods_info['goods_name']}}</td>
                        <td>付款金额：{{$order->order_price}}</td>
                        <td>数量：{{$order->goods_num}}</td>
{{--                        <td>--}}
{{--                            @php--}}
{{--                                $res_arr = [0=>'普通用户',1 => '会员', 2 => '创客', 3 => '瞳小店',4=>'健康馆',5=>'区县代',6=>'市代',7=>'合伙人'];--}}
{{--                                $res = explode(',',$order->order_goods_info['buy_order_info']);--}}
{{--                                foreach ($res as $val){--}}
{{--                                    echo $res_arr[$val].'<br/>';--}}
{{--                                }--}}
{{--                            @endphp--}}

{{--                        </td>--}}
                    </tr>
                    </tbody>
                </table>
        </div>
        @else

            <div class="col-sm">
                <h3 class="text-muted">商品信息</h3>
                <table class="table custom-data-table data-table table-bordered complex-headers">
                    <thead>
                    <tr>
                        <th>商品名称</th>
                        <th>商品价格</th>
                        <th>购买数量</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr>
                        <td style="width: 280px">名称：{{$order->order_group_goods_info['goods_group_name']}}</td>
                        <td>付款金额：{{$order->order_price}}</td>
                        <td>数量：{{$order->goods_num}}</td>
                    </tr>
                    </tbody>
                </table>
            </div>

        @endif


    </div>
    <div class="row" style="margin-top: 12px">
        <div class="col-sm">
            <h3 class="text-muted">收货地址</h3>
                <table class="table custom-data-table data-table table-bordered complex-headers">
                    <thead>
                    <tr>
                        <th>收货人</th>
                        <th>电话</th>
                        <th>收货地址</th>
                    </tr>
                    </thead>
                    <tbody>
                    <tr>
                        <td>{{$order->order_address_info['name']}}</td>
                        <td>{{$order->order_address_info['mobile']}}</td>
                        <td>{{$order->order_address_info['province_val']}}-{{$order->order_address_info['city_val']}}-{{$order->order_address_info['area_val']}} {{$order->order_address_info['address']}}</td>
                    </tr>
                    </tbody>
                </table>
        </div>
    </div>
    @if ($order->status>=4)
        <div class="row" style="margin-top: 12px">
            <div class="col-sm">
                <h3 class="text-muted">物流信息</h3>
                <div class="row">

                </div>
            </div>
        </div>
    @endif


</div>
